package com.sanyog.util;


import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

public class LoadProp {

	private static LoadProp ME = null;
	private Properties props = new Properties();

	private LoadProp() {

		loadProperties();
	}
	
	public static LoadProp getInstance(){
		if(ME==null){
			ME=new LoadProp();
			
		}
		return ME;
	}

	private void loadProperties() {
		InputStream in=this.getClass().getResourceAsStream("/com/sanyog/util/config.properties");
		try {
			props.load(in);
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		
	}
	public String getProp(String key){
		String value=	props.getProperty(key);
		return value;
		}
	
	public static void main(String[] args) {
	LoadProp s=	LoadProp.getInstance();
	System.out.println(s.getProp("INDIAN_DB_NAME")); 
		
	}
	
	
		
	}


